package cn.yunhe.spring.struts.controller;

import org.springframework.beans.factory.annotation.Autowired;

import cn.yunhe.spring.mybatis.model.User;
import cn.yunhe.spring.mybatis.service.IUserService;
/*
 * struts中业务
 */
public class UserAction {
	@Autowired
	private IUserService userService;
	
	private User user;

	public IUserService getUserService() {
		return userService;
	}

	public void setUserService(IUserService userService) {
		this.userService = userService;
	}

	public User getUser() {
		return user;
	}

	public void setUser(User user) {
		this.user = user;
	}
	
	public String findUser(){
	   user = userService.getUser();
	return "success";

	}
}
